package com.lxmes.base.service.impl;

import java.util.List;
import com.lxmes.common.utils.DateUtils;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import com.lxmes.base.mapper.JcIteminfoClassBigMapper;
import com.lxmes.base.domain.JcIteminfoClassBig;
import com.lxmes.base.service.IJcIteminfoClassBigService;

/**
 * 物料大类Service业务层处理
 * 
 * @author 张志煜
 * @date 2022-11-29
 */
@Service
public class JcIteminfoClassBigServiceImpl implements IJcIteminfoClassBigService 
{
    @Autowired
    private JcIteminfoClassBigMapper jcIteminfoClassBigMapper;

    /**
     * 查询物料大类
     * 
     * @param id 物料大类主键
     * @return 物料大类
     */
    @Override
    public JcIteminfoClassBig selectJcIteminfoClassBigById(Long id)
    {
        return jcIteminfoClassBigMapper.selectJcIteminfoClassBigById(id);
    }

    /**
     * 查询物料大类列表
     * 
     * @param jcIteminfoClassBig 物料大类
     * @return 物料大类
     */
    @Override
    public List<JcIteminfoClassBig> selectJcIteminfoClassBigList(JcIteminfoClassBig jcIteminfoClassBig)
    {
        return jcIteminfoClassBigMapper.selectJcIteminfoClassBigList(jcIteminfoClassBig);
    }

    /**
     * 新增物料大类
     * 
     * @param jcIteminfoClassBig 物料大类
     * @return 结果
     */
    @Override
    public int insertJcIteminfoClassBig(JcIteminfoClassBig jcIteminfoClassBig)
    {
        jcIteminfoClassBig.setCreateTime(DateUtils.getNowDate());
        return jcIteminfoClassBigMapper.insertJcIteminfoClassBig(jcIteminfoClassBig);
    }

    /**
     * 修改物料大类
     * 
     * @param jcIteminfoClassBig 物料大类
     * @return 结果
     */
    @Override
    public int updateJcIteminfoClassBig(JcIteminfoClassBig jcIteminfoClassBig)
    {
        jcIteminfoClassBig.setUpdateTime(DateUtils.getNowDate());
        return jcIteminfoClassBigMapper.updateJcIteminfoClassBig(jcIteminfoClassBig);
    }

    /**
     * 批量删除物料大类
     * 
     * @param ids 需要删除的物料大类主键
     * @return 结果
     */
    @Override
    public int deleteJcIteminfoClassBigByIds(Long[] ids)
    {
        return jcIteminfoClassBigMapper.deleteJcIteminfoClassBigByIds(ids);
    }

    /**
     * 删除物料大类信息
     * 
     * @param id 物料大类主键
     * @return 结果
     */
    @Override
    public int deleteJcIteminfoClassBigById(Long id)
    {
        return jcIteminfoClassBigMapper.deleteJcIteminfoClassBigById(id);
    }
}
